package com.example.mydemo.baidu;


import com.baidu.aip.contentcensor.AipContentCensor;
import com.baidu.aip.face.AipFace;

/**
 * 加载模块对象
 * @author gjl
 *
 */
public class BDFactory {

    public static final String APP_ID = "11651798";
    public static final String API_KEY = "p6czaBuvvSEEHRDhtY4PTRgU";
    public static final String SECRET_KEY = "cclc7NeQh5ubF13tppWS0yzfGHi2qG4Z";

    private static AipContentCensor client;


    public static AipContentCensor getAipContentCensor(){
        if(client==null){
            synchronized (AipFace.class) {
                if(client==null){
                    client = new AipContentCensor(APP_ID,API_KEY,SECRET_KEY);
                    System.out.println("---------AipContentCensor instance-------------");
                }
            }
        }
        return client;
    }
}